
import supplier from '@/api/eims/purchase/supplierAPI'
import order from '@/api/eims/purchase/orderAPI'
import stock from '@/api/eims/stockAPI'
import Mixins from '@/views/mixins'
export default {
  mixins: [Mixins],
  methods: {
    getRequestType (opt) {
      if (opt === 'deleteOrder') {
        return order.deleteOrderAPI
      } else if (opt === 'addOrder') {
        return order.addOrderAPI
      } else if (opt === 'updateOrder') {
        return order.updateOrderAPI
      } else if (opt === 'submitOrder') {
        return order.submitOrderAPI
      } else if (opt === 'cancelOrder') {
        return order.cancelOrderAPI
      } else if (opt === 'completedOrder') {
        return order.completedOrderAPI
      } else if (opt === 'rejectOrder') {
        return order.rejectOrderAPI
      } else if (opt === 'getPurchaseOrderInfo') {
        return order.getPurchaseOrderInfo
      } else if (opt === 'getOrderStockInfoList') {
        return order.getOrderStockInfoListAPI
      } else if (opt === 'deleteSupplier') {
        return supplier.deleteSupplierAPI
      } else if (opt === 'updateSupplier') {
        return supplier.updateSupplierAPI
      } else if (opt === 'addSupplier') {
        return supplier.addSupplierAPI
      } else if (opt === 'getProductStorageByAssociateOrder') {
        return stock.getProductStorageByAssociateOrderAPI
      }
    }
  }
}
